-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(nav): Open zendesk when clicking 'contact support' #86068
Conversation
label: t('Contact Support'), | ||
externalHref: `mailto:${ConfigStore.get('supportEmail')}`, | ||
}, | ||
...(contactSupportItem ? [contactSupportItem] : []), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the menuItemProp supports a disabled prop for this use case — I also used to use this ternary + destructuring combo for the issue view nav, but I think the disabled prop should achieve the same behavior.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah it does support disabled, but I don't want this to show up at all if you're self hosted and don't have a support email in the config
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh my b I meant hidden
. but now that I think about it, you'll still have to destructure the contactSupportItem anyways, so this might not make it much cleaner
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ohh I didn't actually know about that property!
Bundle ReportChanges will decrease total bundle size by 6.0kB (-0.01%) ⬇️. This is within the configured threshold ✅ Detailed changes
Affected Assets, Files, and Routes:view changes for bundle: app-webpack-bundle-array-pushAssets Changed:
Files in
Files in
|
This matches the old behavior where in SaaS we would open the zendesk widget when clicking "contact support". We can't use the existing ZendeskLink component because we need to specify the dropdown menu item as an object, so I extracted some logic out to a util file.